//////////////////////////////////////////////////////////////////////////
/// Copyright (c) 2011, Sidorenko 'PC' Alexander                       ///
/// mailto: sidorenko /*dot*/ alexander (at) gmail [dot] com           ///
/// This file is a part of the Radiating Gas Dynamics project          ///
//////////////////////////////////////////////////////////////////////////

#ifndef SodProblem_INCLUDED
#define SodProblem_INCLUDED

#include "ProblemN.h"

class SodProblem : public ProblemN<1>
{
public:

	SodProblem(gdScalar gamma, gdScalar cfl, unsigned int numThreads, BOOL saveFull);
	virtual ~SodProblem();

	void initGrid(gdScalar xMax, unsigned int numCells,
				  // Solving parameters (for Riemann Solver)
				  gdScalar tolerance, unsigned int stepsThreshold);

	// Overloaded from Problem
	virtual unsigned int getNumPlotTypes() const;
	virtual std::string getPlotTypeName(unsigned int id) const;
	virtual void plotSolution(CDC& dc, const CRect& dstRect, const CColorBar& clr, unsigned int timeStep, unsigned int pType);

private:

	// Overloaded from GodunovSolver
	virtual void generateGrid();
	virtual void generateInitialDistributions();
	virtual void applyBoundaryConditions();

	// Overloaded from Problem
	virtual void solveRadiation(gdScalar timeDelta);

	gdScalar m_xMax;

};

#endif // SodProblem_INCLUDED